package org.lds.hotkey.console.common.enums;

import org.lds.hotkey.common.enums.ErrCodeEnum;

public enum ConsoleErrorEnum implements ErrCodeEnum {

    SYSTEM_ERROR("SYSTEM_ERROR", "系统错误"),
    APP_NOT_EXIST("APP_NOT_EXIST", "APP不存在"),

    APP_REFERENCING("APP_REFERENCING", "APP正在被使用"),

    APP_ENABLING("APP_ENABLING", "APP正在被使用"),

    ETCD_SYNC_FAIL("ETCD_SYNC_FAIL", "同步ETCD失败"),

    APP_NAME_NOT_EXIST("APP_NAME_NOT_EXIST", "app名称不存在"),

    ;

    private String code;
    private String message;

    ConsoleErrorEnum(String code, String message) {
        this.code = code;
        this.message = message;
    }

    @Override
    public String getErrCode() {
        return code;
    }

    @Override
    public String getErrMsg() {
        return message;
    }

}
